package wsz.code.client;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RequestParam;
import wsz.code.client.fallback.ServiceUserClientFallBack;

/**
 * @author wsz
 * @date 2021/12/29 17:37
 **/
@Component
@FeignClient(name = "service-user", path = "user", fallback = ServiceUserClientFallBack.class)
public interface ServiceUserClient {

    @RequestMapping(value = "isRegistered/{email}", method = RequestMethod.GET)
    boolean isRegistered(@PathVariable(value = "email") String email);
}
